package com.ruyuan.ingestion.kafka.consumer;

import com.ruyuan.ingestion.common.Persistable;
import com.ruyuan.ingestion.parser.hbase.HBaseUserFriendParser;
import com.ruyuan.ingestion.sink.HBaseWriter;

public class UserFriendConsumer extends BaseConsumer {


    @Override
    protected String getKafkaTopic() {
        return "user_friends";
    }

    @Override
    protected Boolean getKafkaAutoCommit() {
        return false;
    }

    @Override
    protected String getKafkaConsumerGrp() {
        return "userFriend"+getKafkaTopic();
    }

    @Override
    protected Persistable[] getWrites() {
        return new Persistable[] {
                new HBaseWriter("ry_events_db:user_friend",new HBaseUserFriendParser())
        };
    }
}
